package ptumall.service;

import org.springframework.core.io.FileSystemResource;
import org.springframework.util.MultiValueMap;

import java.io.File;
import java.util.Map;

public interface IRestTemplateService {

    <T> T postForObject(String url, MultiValueMap<String, Object> params, Class<T> responseType);

    <T> T postForObject(String url, Map<String, String> headers, MultiValueMap<String, Object> params, Class<T> responseType);

    <T> T postJson(String returnUrl, Map<String, String> headers, Map<String, Object> body, Class<T> responseType);

    FileSystemResource getFileSystemResource(File file);

    FileSystemResource getClassPathFileSystemResource(String path);
}
